package com.customer.crm.system.pojo;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.ibatis.type.Alias;

import javax.persistence.Column;
import java.time.LocalDateTime;

/**
 * @author Lyp
 * @create 2021/12/15
 */

@Data
@NoArgsConstructor
@AllArgsConstructor
@TableName("tb_system_user")
@Alias("systemUser")
public class SystemUser {

    private String id;

    @TableField(fill = FieldFill.INSERT, value = "createTime")
    private LocalDateTime createTime;

    private String email;

    @TableField(value = "password")
    private String password;

    private String phone;

    private String salt;

    @TableField(value = "sortNum")
    private Integer sortNum;

    @TableLogic(value = "0", delval = "1")
    private Integer status;

    @TableField(fill = FieldFill.UPDATE, value = "updateTime")
    private LocalDateTime updateTime;

    @TableField(value = "userNote")
    private String userNote;

    @TableField(value = "userName")
    private String userName;

    @TableField(value = "createBy")
    private String createBy;

    @TableField(value = "updateBy")
    private String updateBy;

    @TableField(exist = false)
    private SystemRole systemRole;


}
